export const ResponseRefre = (refreStr) => {
	// 返回当前页刷新数据
	let pages = uni.$u.pages();
	let currentPage = pages[pages.length - 1]; //当前页面
	if (currentPage) {
		console.log();
		let isKey = currentPage['$vm']['_data'].hasOwnProperty(refreStr);
		let path = currentPage['$page']['fullPath'];
		if (isKey) {
			if (currentPage['$vm']['_data'][refreStr]) {
				currentPage['$vm']['_data'][refreStr] = false;
				console.log(`当前页${path}有刷新标识:${refreStr},isKey:${isKey}`);
				return true;
			}
		} else {
			uni.$u.toast(`当前页data没有该刷新标识字段:${refreStr}`)
			return false;
		}
	}

};
export const RequestRefre = (refreStr) => {
	// 通知上一页刷新数据
	let pages = uni.$u.pages();
	let beforePage = pages[pages.length - 2]; //上一页
	if (beforePage) {
		
		let path = beforePage['$page']['fullPath'];
		let isKey = beforePage['$vm']['_data'].hasOwnProperty(refreStr);
		if (isKey) {
			beforePage['$vm']['_data'][refreStr] = true;
			// console.log(`上一页${path}有刷新标识:${refreStr},isKey:${isKey}`);
		} else {
			return
			// uni.$u.toast(`上一页${path}data没有刷新标识字段:${refreStr}`);
		}
	}
}
